<?php
//Shows a box
//$_COOKIE['prevPage'] = 'Home.php';
//$_COOKIE['prevSearch'] = "";
require('./View/Security.php');
require('./View/BoxView.php');
require('./View/ViewFunctions.php');
require('./Model/SpecalizedInserts.php');
require('./Controller/UpdateBackEnd.php');

//Goes back to Home.php if clicked in view generic


$query = "SELECT CellType.ID AS \"CellTypeID\", CellType.Name AS 'Cell Name', Modification.id AS \"ModificationID\", Modification.Name 'Modification Name', Researcher.ID AS \"ResearcherID\", Researcher.Name, FrozenTube.Location, FrozenTube.ContainerID, FrozenTube.id FROM FrozenTube JOIN CellType ON (FrozenTube.CellTypeID=CellType.ID) JOIN Modification ON (FrozenTube.ModifiedByID=Modification.ID) JOIN Researcher ON ( FrozenTube.FrozenByID=Researcher.ID) WHERE FrozenTube.ContainerID="; 
$query .= $_GET['ContainerID'];
$query .= " ORDER BY Location ASC";
$result = mysql_query($query) or die('Query failed in View Box: ' . mysql_error() . "Query: $query");
//Edit the URL's below to edit where the links on the box page go to'
$select = CreateBoxView($result, array('CellTypeID' => 'ViewGeneric.php', 'ModificationID' => 'ViewGeneric.php', 'ResearcherID' => 'ViewGeneric.php'));

?>

<HTML>
<HEAD>
 <TITLE>Box</TITLE>
 <STYLE type="text/css">}
  A:link { color: 000066 }
  A:visited { color: 000066 }
  p {font-size: 75%}
 </STYLE>
</HEAD>
<BODY link=000066 vlink=000066 alink=000066>
<?php echo searchButton($_GET); ?> </br>
<BUTTON type="button" name="Print" onclick="print()">Print </button>
<p>
<? echo $select ?>
</p>
<?php makeBackButton() ?>
<?php require('./View/Footer.php'); ?>
</BODY>
</HTML